package com.wms.enums;

/**
 * @author TianWenHe
 * @date 2025/4/27
 * @desc
 */
public enum ReturnStatus {
    TO_BE_SORTED("待分拣"),
    TO_BE_STORED("待入库"),
    PARTIALLY_STORED("部分入库"),
    FULLY_STORED("完全入库");

    private final String description;

    ReturnStatus(String description) {
        this.description = description;
    }

    public String getDescription() {
        return description;
    }

    public static ReturnStatus valueOfDescription(String description) {
        for (ReturnStatus status : ReturnStatus.values()) {
            if (status.getDescription().equals(description)) {
                return status;
            }
        }
        throw new IllegalArgumentException("No enum constant com.wms.enums.ReturnStatus." + description);
    }
}
